<template>
  <div>
     <div v-if="kk==1">
       <GoodsList :goodsId="1"></GoodsList>      
     </div>
     <div v-else-if="kk==2">
      <GoodsList :goodsId="2"></GoodsList> 
     </div>
     <div v-else-if="kk==3">
       33333
     </div>
     <div v-else-if="kk==4">
       44444
     </div>
     <div v-else>
        <GoodsList :goodsId="0"></GoodsList>    
     </div>
  </div>
</template>

<script>
import MSG from "../components/msg.js";
//引入
import GoodsList from "./GoodsList";

export default {
   data(){
     return {
        kk: 0
     }
   },
   mounted:function() {
     var that = this
      MSG.$on("val",function(m){
        that.kk = m
      })
   },
   components: {
     GoodsList
   }
}
</script>

<style>

</style>